// #include "./include/car.h"
#include "./src/car_parts/agx.cpp"
#include "./src/car_parts/baseplate.cpp"
#include "./src/car_parts/binocularcamera.cpp"
#include "./src/car_parts/ladar.cpp"
#include "./src/car_parts/gyroscope.cpp"
#include "./src/car_parts/lcd.cpp"
#include "./src/car_parts/battery.cpp"
#include "./src/car.cpp"
#include "./src/student.cpp"
#include "./src/singleton.cpp"

#include "./include/singleton.h"

int main()
{
    CarAllocationSystem &system = CarAllocationSystem::getInstance();
    // 小车信息初始化
    system.car_init();
    // 进行实践3的测试
    std::cout << "-------------------------------------------------------------------\n";
    std::cout << "开始进行障碍物测试，1代表前方障碍，2代表左前方障碍，3代表右前方障碍\n";
    while (true)
    {   
        int order;
        std::cout << "请输入命令：";
        std::cin >> order;
        if (order == 0)
        {
            std::cout << "测试结束\n-------------------------------------------------------------------\n";
            return 0;
        }
        // test函数，1表示小车下标，order是输入命令。几辆车在这个功能并无区别，直接用1演示。
        system.test(1, order);
    }
}